home *** CD-ROM | disk | FTP | other *** search
/ Technotools / Technotools (Chestnut CD-ROM)(1993).ISO / lang_oth / tm480 / tmexam.exe / HOTEMENU.TSK < prev    next >
Text File  |  1991-09-10  |  3KB  |  115 lines

  1. ; Title   : HOTEMENU.TSK                Last Updated : 6th March 1991
  2. ; Author  : Steve Johnson - FmP.        Version      : 1.00
  3. ; Purpose : Example 2 level menu with context sensitive help
  4.  
  5. var char,1
  6. int first_choice,second_choice
  7. logical forever
  8. vconst attention,79
  9. var help_name,3
  10. var tname,8,"HOTEMENU"
  11.  
  12. END
  13.  
  14. forms logon.ovr ;in case /q and registered
  15. lookfor hotemenu.ovr
  16. if not found
  17.   insert tname tname
  18.   put "NO_FORMS"
  19.   stop
  20. fi
  21. forms hotemenu.ovr
  22. until forever
  23.   move 0c000h to bbmask
  24.   move first_choice to choice
  25.   put "B_BAR"
  26.   move hilite to first_choice
  27.   if choice = 30
  28.     stop
  29.   fi
  30.   if choice = 31
  31.     move display to help_name
  32.     put help_name wait 0 noclear
  33.     clear bbdisp
  34.   else
  35.     cursor 14 10 attention choice 5 display 5
  36.     move second_choice to choice
  37.     put "DRINKS"
  38.     move hilite to second_choice
  39.     cursor 15 10 attention choice 5 display 5
  40.     inkey char
  41.   fi
  42. fi
  43. stop
  44. endtask
  45. @VIDEO
  46. @NF B_BAR
  47. @HEAD CENTRE,"Bounce-Bar Snacks"
  48. @bright
  49. @colour page,cyan,blue
  50. @BANNER
  51. @bbimenu cyan,blue
  52. @DRAW
  53.    >C<
  54.  
  55.                           {QUARTER POUNDER WITH CHEESE }
  56.                         {SELECTION OF TOASTED SANDWICHES }
  57.                                   {CHEESE BOARD }
  58.                         {PLOUGHMANS LUNCH (WITH STILTON) }
  59.  
  60.                                                                           >C<
  61.                                 Press <esc> to exit
  62. @WINDOW LINE 17,COLUMN 18,DEPTH 6,WIDTH 44
  63. @gon
  64. 7------------------------------------------9
  65. 0           HELP is available              0
  66. 0 Press  F1 to display  context  sensitive 0
  67. 0 help;  i.e. each topic has its own  help 0
  68. 0 text associated with it.                 0
  69. 1------------------------------------------3
  70. @END
  71. @NF DRINKS
  72. @bbmenu cyan,blue
  73. @bright
  74. @window line8,column4,depth3,width 72
  75. @GON
  76. 4----------------------------------------------------------------------6
  77. 0{NO-DRINK }{TEA }{COFFEE }{COLA }{MILK }{ORANGE JUICE }{ALCOHOL FREE LAGER } 0
  78. 1----------------------------------------------------------------------3
  79. @WINDOW LINE 17,COLUMN 18,DEPTH 6,WIDTH 44
  80. @END
  81. @NF Qua
  82. @colour char,cyan,blue
  83. @WINDOW LINE 18,COLUMN 20,DEPTH 4,WIDTH 40
  84. Highlight a topic using <Space>, <home>
  85. or <arrow> keys then press <return>
  86.               - or -
  87. Press the first character of a topic.
  88. @END
  89. @NF Sel
  90. @colour char,cyan,blue
  91. @WINDOW LINE 18,COLUMN 20,DEPTH 4,WIDTH 40
  92. This  is  an  Instant  Bounce-bar  menu.
  93. Pressing the first character is same  as
  94. highlighting   a  topic   and   pressing
  95. <return>.
  96. @END
  97. @NF Che
  98. @colour char,cyan,blue
  99. @WINDOW LINE 18,COLUMN 20,DEPTH 4,WIDTH 40
  100. Drinks menu is not an instant bounce-bar
  101. menu.   Pressing  first  character  just
  102. highlights  a topic.  Try pressing C  on
  103. next menu (there are 2 "C" topics).
  104. @END
  105. @NF Plo
  106. @colour char,cyan,blue
  107. @WINDOW LINE 18,COLUMN 20,DEPTH 4,WIDTH 40
  108. Context sensitive help like this is easy
  109. to  achieve.  In this case displaying  a
  110. form  named  as first  3  characters  of
  111. topic currently highlighted.
  112. @END
  113. @eof
  114.  
  115.